﻿using System;
using System.Collections.Generic;
using System.Text;

namespace KnowledgeBaseIntermediary
{
    /// <summary>
    /// This is the Interface which is implemented by the Knowledge Base.
    /// </summary>
    public interface IKnowledgeBase
    {
        /// <summary>
        /// This method is used to lookup a reaction to a received UDP String (eg from a sensor. The doorbell for instance.) MAY THROW NotFoundException!
        /// </summary>
        /// <param name="UDPEvent">The received UDP String</param>
        /// <returns>A StateDTO containing all neccessary information of the appropriate state.</returns>
        StateDTO getDTOByEvent(String UDPEvent);

        /// <summary>
        /// This method is used to lookup a reaction to a received voice command. MAY THROW NotFoundException!
        /// </summary>
        /// <param name="command">The received voice command.</param>
        /// <returns>A StateDTO containing all neccessary information of the appropriate state.</returns>
        StateDTO getDTOByCommand(String command);

        /// <summary>
        /// Returns a list of commands available in a given Scene
        /// </summary>
        /// <param name="currentState">The current state of the core</param>
        /// <param name="scene">The requested scene</param>
        /// <returns>A List of all available commands in the requested scene.</returns>
        List<String> getSceneCommands(String currentState, String scene);





        /// <summary>
        /// Used to get an UDP String for a specific command in a given state. MAY THROW NotFoundException!
        /// </summary>
        /// <param name="currentState">The current state of the core</param>
        /// <param name="command">The command for which the UDP String is requested</param>
        /// <returns>A CommandObject comtaining the UDP String, TTS Text & descriptive text</returns>
        CommandObject getUDPByCommand(String currentState, String command);

        /// <summary>
        ///  Get a list of all available states.
        /// </summary>
        /// <returns>The names of all configured states.</returns>
        List<String> getAllAvailableStates();



    }

}